/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package org.gac.gacmod.palette;

import org.gac.gacmod.stepmanager.StepCategory;
import org.gac.gacmod.stepmanager.StepManager;
import org.openide.nodes.Children;
import org.openide.nodes.Node;

/**
 *
 * @author Tomek
 */
public class StepCategoryChildren extends Children.Keys<StepCategory>{

    public StepCategoryChildren()
    {

    }

    @Override
    protected Node[] createNodes(StepCategory arg0)
    {
        StepCategory cat = arg0;
        return new Node[]{ new StepCategoryNode( cat )};
    }

    @Override
    protected void addNotify()
    {
        super.addNotify();
        setKeys(StepManager.Instance.stepCategories());
    }
}
